Conversation
|
jenkins, test this |
|
@jgowdyelastic Can you reissue this PR against master? We'll then backport it to 5.x. |
b01b1aa to
c591bd7
Compare
|
Done, rebased on master and PR is now against master. |
|
@jgowdyelastic Thanks! |
There was a problem hiding this comment.
These should all be const unless you will be overriding the reference, in which case they would be let.
There was a problem hiding this comment.
ok, good point. i've pushed a change for this.
This was just copied from the kibana 4.x prelert app, which doesn't have much ES6 syntax.
|
Please add automated and/or manual tests for this new feature. |
|
Just letting you folks @jgowdyelastic is on vacation, back on Tuesday 11th. He is not ignoring you all. |
thomasneirynck
left a comment
There was a problem hiding this comment.
Looks great! I like the addition. It is very useful addition I think.
I only have some real minor cosmetic things.
There was a problem hiding this comment.
this import is obsolete. linter was also complaining about unused function arguments in this file as well: config, newval, oldVal, $el, attrs
While we're at it, we may as well remove them ;)
There was a problem hiding this comment.
minor: consider reordering the to/from assignments for symmetry with all the others.
There was a problem hiding this comment.
minor: consider removing this comment, I think the code is nice & dense enough to be self explanatory.
There was a problem hiding this comment.
minor: consider not doing the side-effect in this getter/setter. If you prefer to avoid two function-calls, perhaps rename this function to something like setToTimeToAbsoluteAndGetToFrom (yeah, i know :$). But now, this state change is a little buried.
There was a problem hiding this comment.
minor: I wouldn't mind tooltips on these buttons actually. 'move [forward|backward] in time', 'zoom out timeline', 'zoom in timeline'
There was a problem hiding this comment.
sorry to hijack this PR for something a little broader ;)
With the 4 new additions, the top toolbar now looks like the above. From a UI perspective, would it make sense to better isolate the timepicker tools from the "new/save/open/share" buttons. Both are unrelated thematically. Putting a divisor in between/shading background differently/ .... might make the grouping a little clearer. @alt74, @cjcenizal, thoughts (?)
There was a problem hiding this comment.
I think that, ultimately, we should rebuild the timepicker component so that these arrow buttons are part of the dropdown that appears when you click the time range. I don't think the user needs to have them visible at all times. However, this will take some time to implement, and I don't think we should hold up this PR for that.
I think the immediate problem is that the "back" arrow blends in with the + and - icons. We can create the separation you mention by moving them both to the right side, and letting the time range itself create visual separation:
As an additional benefit, the user doesn't need to move the mouse as far when navigating back and forward in succession.
What do you think?
There was a problem hiding this comment.
I agree that the timepicker controls should be obviously separate from the rest of the menu.
I've added a separator as I think it's the simplest and less intrusive solution.

I prefer the arrow buttons being either side of the date range as it's obvious that you'll be moving either side of the displayed range.
But it doesn't make too much difference either way. So I'm happy to be overridden.
Ultimately I think these controls should remain in the navigation bar and not inside the dropdown. They provide a fast way of navigating through time and made a noticeable difference when we originally added them to the Prelert app.
There was a problem hiding this comment.
I think this looks good. I'm not 100% confident about it but that's because I haven't used it as much as you have. Once I've had the chance to use it for awhile I'm sure I'll either be on board or be able to provide some better suggestions. :)
There was a problem hiding this comment.
IMHO, the arrows work better on either side of the range, for the reasons mentioned by @jgowdyelastic
src/ui/public/styles/base.less
Outdated
There was a problem hiding this comment.
This can just be .time-nav-btn because using the element selector increases the selector's specificity unnecessarily.
There was a problem hiding this comment.
agreed. element selector removed
There was a problem hiding this comment.
I think that, ultimately, we should rebuild the timepicker component so that these arrow buttons are part of the dropdown that appears when you click the time range. I don't think the user needs to have them visible at all times. However, this will take some time to implement, and I don't think we should hold up this PR for that.
I think the immediate problem is that the "back" arrow blends in with the + and - icons. We can create the separation you mention by moving them both to the right side, and letting the time range itself create visual separation:
As an additional benefit, the user doesn't need to move the mouse as far when navigating back and forward in succession.
What do you think?
254c731 to
2f7f251
Compare
|
Could I ask for some screenshots or a quick animated gif in this PR? Will help reviewers that don't have time to check it out to at least have an idea where in the interface these new buttons are. |
src/ui/public/styles/base.less
Outdated
There was a problem hiding this comment.
+1 for me, I think it looks good.
|
@tanya this was buried in one of those "outdated" collapsing sections, but here is a screenshot to what it looks like: #8546 (comment). The arrows move the time forward and backward with the size of the current interval, and the magnifiers zoom out and or zoom in the time with a factor of two |
There was a problem hiding this comment.
ha, embarrassing....
i've corrected this, thanks
|
I find the icons confusing, but there are tooltips so it's probably good enough. However, I think we should add better descriptions to the tooltips. For example, I think Also, to me something looks off about the spacing between all the timepicker controls. I think it needs tighter spacing between the controls, plus I think it should have the same amount of padding on each side of the new border. |
2f7f251 to
efad64d
Compare
|
I'll echo what @tbragin said, some screenshots and a gif in the description, along with some extra explanation of the details of how this is supposed to behave would be very helpful. |
|
Replaced by #9253. |




Adds zoom in/out and move left/right buttons to kibana's time picker.
Closes #1956